home *** CD-ROM | disk | FTP | other *** search
/ Cream of the Crop 26 / Cream of the Crop 26.iso / program / p063b9s.zip / UNIT / POPTYPES.PAS < prev    next >
Pascal/Delphi Source File  |  1997-01-29  |  66KB  |  1,411 lines

  1. UNIT PoPTypes;
  2. {╔══════════════════════════════════════════════════════════════════════════╗}
  3. {║ Global types & constants                      Last changed: 29.01.97  SA ║}
  4. {║                                                                          ║}
  5. {║                         (C) Copyright 1989-97 by                         ║}
  6. {║       Dan Wulff, Jens Sandalgaard, Steen Christensen & S¢ren Ager        ║}
  7. {║                                                                          ║}
  8. {║ This source can be distributed freely, as long as it is done in a        ║}
  9. {║ lawfull and friendly manner.                                             ║}
  10. {╚══════════════════════════════════════════════════════════════════════════╝}
  11. {$I POPDEFS.INC}
  12.  
  13. {$IFNDEF NoOPro}
  14.   {$I OPDEFINE.INC}
  15.  
  16.   {$IFNDEF FourByteDates}
  17.     Portal requires FourByteDates to be defined!
  18.   {$ENDIF}
  19. {$ENDIF}
  20.  
  21. INTERFACE
  22.  
  23. {$IFDEF NoOPro}
  24. USES Use32, Dos;
  25.  
  26. CONST
  27.   MaxSearchLen     = 30;
  28.   MaxSearchOptions =  5;
  29.  
  30. TYPE
  31.   DayType   = (Sunday, Monday, Tuesday, Wednesday, Thursday, Friday, Saturday);
  32.   Date      = LongInt;       { Days since ??          }
  33.   Time      = LongInt;       { Seconds since midnight }
  34.   DateTimeRec = RECORD
  35.     D : Date;
  36.     T : Time;
  37.   END;
  38.   ColorSet  = ARRAY[1..62] OF Byte;
  39.   MarkerRec = RECORD
  40.     Line, Col : SmallInt;
  41.   END;
  42.   EventTimer = record
  43.     StartTics : LongInt;
  44.     ExpireTics : LongInt;
  45.   end;
  46. {$ELSE}
  47. USES Use32, Dos, OpCrt, OpDate, OpEditor, ApTimer;
  48. {$ENDIF}
  49.  
  50. TYPE
  51.   { All String types, very handy! }
  52.   S1=STRING[1]; S2=STRING[2]; S3=STRING[3]; S4=STRING[4]; S5=STRING[5];
  53.   S6=STRING[6]; S7=STRING[7]; S8=STRING[8]; S9=STRING[9]; S10=STRING[10];
  54.   S11 =STRING[11]; S12=STRING[12]; S13=STRING[13]; S14=STRING[14]; S15=STRING[15];
  55.   S16 =STRING[16]; S17=STRING[17]; S18=STRING[18]; S19=STRING[19]; S20=STRING[20];
  56.   S21 =STRING[21]; S22=STRING[22]; S23=STRING[23]; S24=STRING[24]; S25=STRING[25];
  57.   S26 =STRING[26]; S27=STRING[27]; S28=STRING[28]; S29=STRING[29]; S30=STRING[30];
  58.   S31 =STRING[31]; S32=STRING[32]; S33=STRING[33]; S34=STRING[34]; S35=STRING[35];
  59.   S36 =STRING[36]; S37=STRING[37]; S38=STRING[38]; S39=STRING[39]; S40=STRING[40];
  60.   S41 =STRING[41]; S42=STRING[42]; S43=STRING[43]; S44=STRING[44]; S45=STRING[45];
  61.   S46 =STRING[46]; S47=STRING[47]; S48=STRING[48]; S49=STRING[49]; S50=STRING[50];
  62.   S51 =STRING[51]; S52=STRING[52]; S53=STRING[53]; S54=STRING[54]; S55=STRING[55];
  63.   S56 =STRING[56]; S57=STRING[57]; S58=STRING[58]; S59=STRING[59]; S60=STRING[60];
  64.   S61 =STRING[61]; S62=STRING[62]; S63=STRING[63]; S64=STRING[64]; S65=STRING[65];
  65.   S66 =STRING[66]; S67=STRING[67]; S68=STRING[68]; S69=STRING[69]; S70=STRING[70];
  66.   S71 =STRING[71]; S72=STRING[72]; S73=STRING[73]; S74=STRING[74]; S75=STRING[75];
  67.   S76 =STRING[76]; S77=STRING[77]; S78=STRING[78]; S79=STRING[79]; S80=STRING[80];
  68.   S81 =STRING[81]; S82=STRING[82]; S83=STRING[83]; S84=STRING[84]; S85=STRING[85];
  69.   S86 =STRING[86]; S87=STRING[87]; S88=STRING[88]; S89=STRING[89]; S90=STRING[90];
  70.   S91 =STRING[91]; S92=STRING[92]; S93=STRING[93]; S94=STRING[94]; S95=STRING[95];
  71.   S96 =STRING[96]; S97=STRING[97]; S98=STRING[98]; S99=STRING[99]; S100=STRING[100];
  72.   S101=STRING[101]; S102=STRING[102]; S103=STRING[103]; S104=STRING[104]; S105=STRING[105];
  73.   S106=STRING[106]; S107=STRING[107]; S108=STRING[108]; S109=STRING[109]; S110=STRING[110];
  74.   S111=STRING[111]; S112=STRING[112]; S113=STRING[113]; S114=STRING[114]; S115=STRING[115];
  75.   S116=STRING[116]; S117=STRING[117]; S118=STRING[118]; S119=STRING[119]; S120=STRING[120];
  76.   S121=STRING[121]; S122=STRING[122]; S123=STRING[123]; S124=STRING[124]; S125=STRING[125];
  77.   S126=STRING[126]; S127=STRING[127]; S128=STRING[128]; S129=STRING[129]; S130=STRING[130];
  78.   S131=STRING[131]; S132=STRING[132]; S133=STRING[133]; S134=STRING[134]; S135=STRING[135];
  79.   S136=STRING[136]; S137=STRING[137]; S138=STRING[138]; S139=STRING[139]; S140=STRING[140];
  80.   S141=STRING[141]; S142=STRING[142]; S143=STRING[143]; S144=STRING[144]; S145=STRING[145];
  81.   S146=STRING[146]; S147=STRING[147]; S148=STRING[148]; S149=STRING[149]; S150=STRING[150];
  82.   S151=STRING[151]; S152=STRING[152]; S153=STRING[153]; S154=STRING[154]; S155=STRING[155];
  83.   S156=STRING[156]; S157=STRING[157]; S158=STRING[158]; S159=STRING[159]; S160=STRING[160];
  84.   S161=STRING[161]; S162=STRING[162]; S163=STRING[163]; S164=STRING[164]; S165=STRING[165];
  85.   S166=STRING[166]; S167=STRING[167]; S168=STRING[168]; S169=STRING[169]; S170=STRING[170];
  86.   S171=STRING[171]; S172=STRING[172]; S173=STRING[173]; S174=STRING[174]; S175=STRING[175];
  87.   S176=STRING[176]; S177=STRING[177]; S178=STRING[178]; S179=STRING[179]; S180=STRING[180];
  88.   S181=STRING[181]; S182=STRING[182]; S183=STRING[183]; S184=STRING[184]; S185=STRING[185];
  89.   S186=STRING[186]; S187=STRING[187]; S188=STRING[188]; S189=STRING[189]; S190=STRING[190];
  90.   S191=STRING[191]; S192=STRING[192]; S193=STRING[193]; S194=STRING[194]; S195=STRING[195];
  91.   S196=STRING[196]; S197=STRING[197]; S198=STRING[198]; S199=STRING[199]; S200=STRING[200];
  92.   S201=STRING[201]; S202=STRING[202]; S203=STRING[203]; S204=STRING[204]; S205=STRING[205];
  93.   S206=STRING[206]; S207=STRING[207]; S208=STRING[208]; S209=STRING[209]; S210=STRING[210];
  94.   S211=STRING[211]; S212=STRING[212]; S213=STRING[213]; S214=STRING[214]; S215=STRING[215];
  95.   S216=STRING[216]; S217=STRING[217]; S218=STRING[218]; S219=STRING[219]; S220=STRING[220];
  96.   S221=STRING[221]; S222=STRING[222]; S223=STRING[223]; S224=STRING[224]; S225=STRING[225];
  97.   S226=STRING[226]; S227=STRING[227]; S228=STRING[228]; S229=STRING[229]; S230=STRING[230];
  98.   S231=STRING[231]; S232=STRING[232]; S233=STRING[233]; S234=STRING[234]; S235=STRING[235];
  99.   S236=STRING[236]; S237=STRING[237]; S238=STRING[238]; S239=STRING[239]; S240=STRING[240];
  100.   S241=STRING[241]; S242=STRING[242]; S243=STRING[243]; S244=STRING[244]; S245=STRING[245];
  101.   S246=STRING[246]; S247=STRING[247]; S248=STRING[248]; S249=STRING[249]; S250=STRING[250];
  102.   S251=STRING[251]; S252=STRING[252]; S253=STRING[253]; S254=STRING[254]; S255=STRING[255];
  103.  
  104.   DosPathStr = String[79];
  105.  
  106.   { Various types for type casting buffers etc. }
  107.   BT = ARRAY[1..65521] of Byte;
  108.   CT = ARRAY[1..65521] of Char;
  109.   BT0= ARRAY[0..65520] of Byte;
  110.   CT0= ARRAY[0..65520] of Char;
  111.  
  112. CONST
  113.   Ver = '0.63'
  114.  
  115.   { Add α, ß or Γ to version }
  116. {$IFNDEF Public}
  117.   {$IFDEF Gamma}
  118.     +'Γ'
  119.   {$ELSE}
  120.     {$IFDEF Beta}
  121.     +'ß'
  122.     {$ELSE}
  123.     +'α'
  124.     {$ENDIF}
  125.     +'9'           { Alpha/Beta release nr.}
  126.   {$ENDIF}
  127. {$ENDIF}
  128.  
  129. {$IFDEF PoPLite}
  130.   +'/Lite'
  131. {$ENDIF}
  132.  
  133.   { Add compilation type to version }
  134. {$IFDEF StonyBrook}
  135.   +'/SB'
  136. {$ELSE}
  137.   {$IFDEF DPMI}
  138.   +'/DPMI'
  139.   {$ELSE}
  140.     {$IFDEF OS2}
  141.     +'/OS2'
  142.     {$ELSE}
  143.       {$IFOPT G-}
  144.       +'/XT'        { '/286' Changed because somebody don't understand.... }
  145.       {$ENDIF}
  146.     {$ENDIF}
  147.   {$ENDIF}
  148. {$ENDIF}
  149.   ;
  150.  
  151.   MaxBaudStat      =  60;                 { Max. baudrates for PORTAL.STA    }
  152.   MaxAddresses     =  16;
  153.   CfgVersion       =   4;                 { Current version of the .CFG file }
  154.   PoPProductCode   = $69;
  155.  
  156.   LinesForStat     =  32;
  157.   MaxActivityLines =  80;
  158.  
  159.   { EMSI STRING constants }
  160.   EMSIINQStr     = '**EMSI_INQC816';
  161.   EMSIREQStr     = '**EMSI_REQA77E';
  162.   EMSIACKStr     = '**EMSI_ACKA490';
  163.   EMSINAKStr     = '**EMSI_NAKEEC3';
  164.  
  165.   On             = True;
  166.   Off            = False;
  167.   High           = True;
  168.   Low            = False;
  169.  
  170.   { FileMode constants }
  171.   ShareRead      = $00;
  172.   ShareWrite     = $01;
  173.   ShareRW        = $02;
  174.   ShareDenyRW    = $10;
  175.   ShareDenyW     = $20;
  176.   ShareDenyR     = $30;
  177.   ShareDenyNone  = $40;
  178.   ShareExclusiv  = $80;
  179.  
  180.   clAreaMan      =   1;
  181.   clJump2Event   =   2;
  182.   clMacroDefeat  =   4;
  183.   clNoModem      =   8;
  184.   clCheckOnLine  =  16;
  185.   clCompileNl    =  32;
  186.   clMailScan     =  64;
  187.   clMailPack     = 128;
  188.   clMailToss     = 256;
  189.   clPoPEd        = 512;
  190.   clPoPList      =1024;
  191.  
  192.   { For own objects in streams }
  193.   otTPoPEntryScreen = 1200;
  194.   otTPoPMenu        = 1201;
  195.  
  196.   veTPoPEntryScreen =    0;
  197.   veTPoPMenu        =    0;
  198.  
  199. {----------------------------------------------------------------------------}
  200. { ASCII Values                                                               }
  201. {----------------------------------------------------------------------------}
  202.   Soh    = 01;
  203.   Stx    = 02;
  204.   Etx    = 03;
  205.   Eot    = 04;
  206.   Enq    = 05;
  207.   Ack    = 06;
  208.   Bs     = 08;
  209.   Lf     = 10;
  210.   Cr     = 13;
  211.   Nak    = 21;
  212.   Syn    = 22;
  213.   Etb    = 23;
  214.   Can    = 24;
  215.   Sub    = 26;
  216.   Escape = 27;
  217.   TSync  = $ae;
  218.   YooHoo = $f1;
  219.  
  220. {=== File names ============================================================}
  221.   PoPMsgAreaFileName      = 'PORTAL.ARE';
  222.   PoPBimodemCfgFileName   = 'PORTAL.BMC';
  223.   PoPBadWaZooFileName     = 'PORTAL.BWZ';
  224.   PoPDataFileName         = 'PORTAL.DAT';
  225.   PoPDailyReqInfoFileName = 'PORTAL.DRI';
  226.   PoPMsgDupeFileName      = 'PORTAL.EDS';
  227.   PoPEventFileName        = 'PORTAL.EVT';
  228.   PoPCfgExportFileName    = 'PORTAL.EXP';
  229.   PoPFileFwdFileName      = 'PORTAL.FWD';
  230.   PoPGenericAreaFile      = 'PORTAL.GAF';
  231.   PoPHelpFileName         = 'PORTAL.HLP';
  232.   PoPInterComFileName     = 'PORTAL.ICF';
  233.   PoPBiModemInterComLog   = 'PORTAL.ICL';
  234.   PoPDumbTermImageName    = 'PORTAL.IMG';
  235.   PoPLogFileName          = 'PORTAL.LOG';
  236.   PoPListSegmentsName     = 'PORTAL.MFS';
  237.   PoPNetFileName          = 'PORTAL.NET';
  238.   PoPNodelistIdxBuffer    = 'PORTAL.NIB';
  239.   PoPNLSegmentFileName    = 'PORTAL.NLS';
  240.   PoPNLTranslateFileName  = 'PORTAL.NLT';
  241.   PoPNodesFileName        = 'PORTAL.NOD';
  242.   PoPOkFileName           = 'PORTAL.OKF';
  243. {$IFDEF OS2}
  244.   PoPResourceFileName     = 'PORTAL2.RES';
  245. {$ELSE}
  246.   PoPResourceFileName     = 'PORTAL.RES';
  247. {$ENDIF}
  248.   PoPScheduleFileName     = 'PORTAL.SCD';
  249.   PoPStatisticsFileName   = 'PORTAL.STA';
  250.   PoPSwapFileName         = 'PORTAL.SWP';
  251.   PoPDumbTermDialDirName  = 'PORTAL.TDD';
  252.   PoPTextEditorPickFile   = 'PORTAL.TEP';
  253.   PoPTickFileName         = 'PORTAL.TIC';
  254.   PoPReceivedFiles        = 'PORTAL.TIT';
  255.   PoPTemplateFileName     = 'PORTAL.TPL';
  256.   PoPDumbTermLogFileName  = 'PORTAL.TRM';
  257.   PoPUndialFileName       = 'PORTAL.UDF';
  258.  
  259.   PoPCfgFileName    : S12 = 'PORTAL.CFG';
  260.  
  261. TYPE
  262.   { FidoNet Packet Header }
  263.   TPktHeader = RECORD
  264.     OrigNode,
  265.     DestNode      : SmallInt;
  266.     Year,
  267.     Month,
  268.     Day,
  269.     Hour,
  270.     Min,
  271.     Sec,
  272.     Baud          : SmallWord;
  273.     Filler1,                               { Always = 2 }
  274.     OrigNet,
  275.     DestNet       : SmallInt;
  276.     Product,
  277.     SerialNo      : Byte;
  278.     Password      : ARRAY[1..8] OF Char;
  279.     OrigZone,
  280.     DestZone,
  281.     AuxNet        : SmallInt;
  282.     CWValLow,
  283.     CWValHigh     : Byte;
  284.     Product2,
  285.     SerialNo2     : Byte;
  286.     Capabil       : SmallWord;
  287.     OrigZone2,
  288.     DestZone2     : SmallInt;
  289.     OrigPoint,
  290.     DestPoint     : SmallInt;
  291.     Data          : ARRAY[1..4] OF Byte;
  292.   END;
  293.  
  294.   { FidoNet Message Header Type }
  295.   TPktMsgHeader = RECORD
  296.     StartMsg,                              { $0200 }
  297.     OrigNode,
  298.     DestNode,
  299.     OrigNet,
  300.     DestNet,
  301.     Attr,
  302.     Cost       : SmallInt;
  303.     Time       : ARRAY[1..20] OF Char;
  304.   END;
  305.  
  306.   { Nodelist Types supported }
  307.   NodeListType   = (NewNodelistType,
  308.                     QBBSNodelistType,
  309.                     RANodelistType,
  310.                     Version7,
  311.                     SBBSNodeListType);
  312.  
  313.   CostType = RECORD                     { Nodelist Cost Table record }
  314.     Prefix : S10;
  315.     Cost   : SmallWord;
  316.   END;
  317.   CostTab = ARRAY[1..1000] OF CostType;
  318.  
  319.   { A 4D FidoNet address }
  320.   TFidoAddress = RECORD
  321.      Zone,
  322.      Net,
  323.      Node,
  324.      Point : SmallInt;
  325.    END;
  326.  
  327.   SendToTabType = ARRAY[1..50] OF TFidoAddress;
  328.  
  329. {┌──────────────────────────────────────────────────────────────────────────┐}
  330. {│ YooHoo Stuff - See FTSC-06 for more info.                                │}
  331. {└──────────────────────────────────────────────────────────────────────────┘}
  332.   TYooHooCap = (YDietIfna,    { Can do SeaLink                            }
  333.                 FtbUser,      { Full Tilt Boogie??                        }
  334.                 ZedZipper,    { Can do ZModem 1K  (Normal ZModem)         }
  335.                 ZedZapper,    { Can do ZModem 8K                          }
  336.                 DoesJanus,    { Can do Janus                              }
  337.                 DoesHydra,    { Can do Hydra                              }
  338.                 Bit6,
  339.                 Bit7,
  340.                 Bit8,
  341.                 Bit9,
  342.                 CanDoBiMail,  { Can do BiModem (NOT STANDARD)             }
  343.                 BitB,
  344.                 BitC,
  345.                 BitD,
  346.                 BitE,
  347.                 WzFreq);      { Accepts file requests                     }
  348.  
  349.   YooHooCapSet = SET OF TYooHooCap;
  350.  
  351.   { WaZOO packet type }
  352.   THelloPacket = RECORD
  353.     Signal,
  354.     HelloVersion,
  355.     ProductCode,
  356.     ProductMaj,
  357.     ProductMin     : SmallWord;
  358.     SystemName     : ARRAY[1..60] OF Char;
  359.     Sysop          : ARRAY[1..20] OF Char;
  360.     Address        : TFidoAddress;
  361.     Password       : ARRAY[1..8] OF Char;
  362.     Reserved2      : ARRAY[1..8] OF Char;
  363.     Capabilities   : YooHooCapSet;
  364.     Reserved3      : ARRAY[1..12] OF Char;
  365.   END;
  366.  
  367.   SendToType = ARRAY[1..2] Of S50;
  368.  
  369.   TFunctionKey = RECORD
  370.     ErrorLevel     : Byte;
  371.     Description    : S70;
  372.   END;
  373.  
  374. {┌──────────────────────────────────────────────────────────────────────────┐}
  375. {│ Contents : Configuration information.                                    │}
  376. {│ FileName : PORTAL.CFG                                                    │}
  377. {│ Size     : 10240 bytes                                                   │}
  378. {│ Comments :                                                               │}
  379. {└──────────────────────────────────────────────────────────────────────────┘}
  380. CONST
  381.   itd_Tick = 1;
  382.   itd_File = 2;
  383.   itd_Mail = 4;
  384.  
  385. TYPE
  386.   TNodeStat = (nsUnknown, nsKnown, nsPassword);
  387.   TReqLimit = (rlPrCall, rlPrDay);
  388.   TBBSType  = (btNone, btQBBS, btProBoard, btOpus110, btRA, btOpus170, btSBBS, btMax);
  389.   TReqOnUs  = (ru_Noway, ru_Always, ru_Cost);
  390.  
  391.   TConfig = RECORD
  392.     Version        : Byte;             { .CFG file version                   }
  393.     TaskNumber     : Byte;             { Which task number are we            }
  394.     SwapDir        : DosPathStr;          { Where to swap to                    }
  395.     Filler1        : DosPathStr;
  396.     Outbound,                          { Outbound directories                }
  397.     Banner,                            { Name of banner to show callers      }
  398.     DefaultMacro,                      { Name of default keyboard-macro file }
  399.     Editor,                            { Command to envoke message editor    }
  400.     LogfileName    : DosPathStr;          { Log file for your system            }
  401.     LogLevel       : Byte;             { Desired log level (1-5)             }
  402.     UseYearInLog   : Boolean;          { False= ! dd-nnn hh:mm PORTAL        }
  403.                                        { True = ! dd-nnn-yy hh:mm PORTAL     }
  404.     NodeList       : DosPathStr;          { Directory of your nodelist files    }
  405.     NodelistTyp    : NodeListType;     { Type of nodelist used               }
  406.  
  407.     MainAdrNum     : Byte;
  408.     Addresses      : ARRAY[1..MaxAddresses] Of TFidoAddress;
  409.                                        { Defined addresses                   }
  410.     PointNet       : SmallInt;          { Number of point-net (for fake)      }
  411.     UseFakeAddress : Boolean;          { Should PORTAL Use fake or real      }
  412.                                        { addresses                           }
  413.     Sysop          : S20;              { Name of SysOp                       }
  414.     System         : S60;              { Name of system                      }
  415.     SwapOnExec     : Boolean;          { Swap on exec of any command         }
  416.     EnterBBSText,                      { Text displayed while loading        }
  417.                                        { BBS software                        }
  418.     DoingMailText,                     { Text to display, while in a         }
  419.                                        { mail-only event                     }
  420.     PressESCText   : DosPathStr;          { Text displayed when user should     }
  421.                                        { press ESC                           }
  422.     MaxRinging     : Byte;             { Max RINGING on calls out            }
  423.     ZMHStart,                          { Start of Zone Mail Hour             }
  424.     ZMHEnd,                            { End of Zone Mail Hour               }
  425.     CallTime,                          { Global call frequency               }
  426.     CallWidth      : Time;             { Global max call delay               }
  427.     ConnectFastest : Boolean;          { Check node list for max. speed      }
  428.                                        { and abort poll, if lower            }
  429.     OutReReadDelay : Time;             { Delay between reading outbound      }
  430.                                        { information                         }
  431.     FuncReqPwd     : S20;              { Password for function requests      }
  432.     UseJanus       : Boolean;          { Allow Janus protocol                }
  433.     UseEMSI        : Boolean;          { Allow EMSI hand shake               }
  434.     FastCalls      : Boolean;          { Call systems faster than us         }
  435.     KeepEmptyDirs  : Boolean;          { If Yes, don't delete Zone, 4D Point }
  436.     Curmudgeon     : Boolean;          { If Yes, hang up on calls from       }
  437.                                        { unknown systems           SA:930330 }
  438.     RereadOnCall   : Boolean;          { If set to Y, PoP will reread the    }
  439.                                        { outbound if there is nothing to send}
  440.     Inbound        : ARRAY[TNodeStat] OF DosPathStr;
  441.     InboundToDo    : ARRAY[TNodeStat] OF SmallWord;
  442.     TaskType       : BYTE;             { 0=Normal, 1=Is Request server, }
  443.                                        { 2=Running under Request server }
  444.     HexTask        : Boolean;              { No = MakeTaskFileName makes decimal numbers  SA:940610}
  445.     Filler         : ARRAY[1..22] of Byte;
  446.     FKey           : ARRAY[1..2, 1..10] OF TFunctionKey;    { See above      }
  447.     Color          : ARRAY[1..4] OF ColorSet;               { See above      }
  448.     BBS : RECORD
  449.       BBSType        : TBBSType;       { BBS Type used                       }
  450.       Path           : DosPathStr;        { Path to BBS-information files       }
  451.       UserFile       : DosPathStr;        { Name of user file, for user editor  }
  452.       MinBaud        : SmallWord;           { Min. baud to enter BBS              }
  453.       MinBaudFile    : DosPathStr;        { File to show slower callers         }
  454.       UserErrorLevel : Byte;           { Error level for all callers         }
  455.       Multi : ARRAY[1..5] OF RECORD
  456.         Key     : Char;                { Key to select BBS                   }
  457.         BatName : S8;                  { Name of .BAT file to create         }
  458.       END;
  459.       DefFile        : S8;             { Name of BBS definition file         }
  460.       Filler         : ARRAY[1..55] of Byte;
  461.     END;
  462.     Modem : RECORD
  463.       CommPort   : Byte;                    { Comm. port number              }
  464.       BaudRate   : SmallWord;                    { Baud rate to initialize modem  }
  465.       PreInit    : S40;                     { ??? }
  466.       Init       : S80;                     { Init. command                  }
  467.       NoAnswer,                             { Init cmd. in NoAnswer event    }
  468.       Dial,                                 { Dial command                   }
  469.       Busy,                                 { Cmd. to make line busy         }
  470.       HangUp,                               { Hang-up command                }
  471.       Answer     : S40;                     { Answer command                 }
  472.       ReInit     : Time;                    { Delay between modem inits,     }
  473.                                             { while the system is idle       }
  474.       LockedBaud : S10;                     { Part of connect STRING, to tell}
  475.                                             { the system that the baud rate  }
  476.                                             { should remain locked (/ARQ)    }
  477.       ExitStr : ARRAY[1..5] Of RECORD
  478.         ConStr : S10;                       { Special exit STRING e.g. /FAX  }
  479.         ErrLvl : Byte;                      { Exit error level for above str }
  480.       END;
  481.       ModemType : ARRAY[0..7] OF RECORD
  482.         Bit     : Byte;
  483.         Dial    : S40;
  484.         DialOut : Boolean;
  485.         Baud    : SmallWord;
  486.       END;
  487.       WaitTime    : Time;              { Sek. to wait for logon   250593 SBC }
  488.       InternalFax : Boolean;           { Use internal fax receive  191093 SA }
  489.       LinkStat    : S10;
  490.       LogLines    : Byte;
  491.       Filler      : ARRAY[1..7] OF Byte;
  492.     END;
  493.  
  494.     Screen         : RECORD
  495.       BlankTime      : Time;           { Time of inactivity, before blanking }
  496.                                        { the screen                          }
  497.       ChkSnow,                         { Check for 'snow' during screen      }
  498.                                        { updates (CGA only)                  }
  499.       KeepOffScrMode,                  { Allow to change screen mode         }
  500.       ScrMode,                         { False=25, True=43/50 lines          }
  501.       HardwareBlank,                   { Blank using hardware interrupt      }
  502.       ExplodingWin   : Boolean;        { Use fancy display of menus and      }
  503.                                        { windows                             }
  504.       Filler         : ARRAY[1..2] OF Byte;
  505.     END;
  506.     Statistics : RECORD
  507.       MdmProtocol : ARRAY[1..5] OF S5;
  508.     END;
  509.     ListFiles : RECORD
  510.       FileList,                          { Name of finished file list         }
  511.       NewsList,                          { Name of new files list             }
  512.       Header,                            { Name of header file for file list  }
  513.       Footer,                            { Name of footer file for file list  }
  514.       TopFile,                           { Name of most downloaded files list }
  515.       StatFile       : DosPathStr;          { Name of area statistics file       }
  516.       Adopt          : Boolean;          { Adopt orphan files while running   }
  517.       AdoptComment   : S40;              { Comment for adopted files          }
  518.       DupeCheck      : Boolean;          { Perform dupe check of file base    }
  519.       Stat           : Boolean;          { Include statistics file in Filelist}
  520.       IncludeTop     : Boolean;          { Include top list in file list      }
  521.       Top            : Byte;             { How many files (0-50) to include in}
  522.                                          { top downloads list                 }
  523.       DkDate         : Boolean;          { Use european date format           }
  524.       NewsDays       : Byte;             { How old files to include in news   }
  525.                                          { file                               }
  526.       Threshold      : Byte;             { DupeCheck Size Threshold           }
  527.       RemMissing,                        { Remove Missing Files               }
  528.       OkPortal,                          { Update portal compatible ok file   }
  529.       ZapZero,                           { Delete zero Byte files             }
  530.       Touch          : Boolean;          { Touch files with invalid time stamp}
  531.       CrapFiles,                            { Files to delete                 }
  532.       ExcludeFiles,                         { Files not to include in FileList}
  533.       NoDupeCheck    : ARRAY[1..10] of S12; { Files not to check for dupes    }
  534.       NonAdoptFiles  : ARRAY[1..10] of S12; { Files not to adopt              }
  535.       NonAdoptAreas  : ARRAY[1..10] of S3;  { Areas not to adopt files in     }
  536.       PrivateAreas   : ARRAY[1..11] of S3;  { Areas to leave out from list    }
  537.       DoBefore       : DosPathStr;             { Command to do before generation }
  538.       DoAfter        : DosPathStr;             { Command to do after generation  }
  539.       DoPack         : DosPathStr;             { Command to pack finished list   }
  540.       DupeReport     : DosPathStr;             { DupeReport filename             }
  541.       TXTFreq        : ARRAY[0..3] of S55;  { Txt to display if Freq is OK    }
  542.       OkBimodempath  : DosPathStr;             { Bimodem compatible OK-File      }
  543.       Filler         : ARRAY[1..32] of Byte;
  544.     END;
  545.  
  546.                         { 1..3, 1..2 (PrCall, PrDay) }
  547.     Request : RECORD
  548.       Limit : ARRAY[TNodeStat,TReqLimit] OF RECORD
  549.         MaxFiles : SmallWord;
  550.         MaxTime  : Time;
  551.         MaxBytes : LongInt;
  552.       END;
  553.       RspAsPkt       : Boolean;
  554.       SkipAfterFirst : Boolean;        { Skip search after first matching    }
  555.                                        { file - if no jokers in requested    }
  556.                                        { name                                }
  557.       MinBaud        : SmallWord;           { Minimum baudrate required for       }
  558.                                        { requests                  SA:170593 }
  559.       ReqOnUs        : TReqOnUs;
  560.       ReqOnUsCost    : SmallWord;
  561.       Filler         : ARRAY[1..58] of Byte;
  562.     END;
  563.  
  564.     MailScanner    : RECORD
  565.       Filler1      : ARRAY[1..50] OF Char;
  566.       RenumThresh  : SmallInt;
  567.       NetMailDir   : DosPathStr;
  568.       Filler3      : DosPathStr;
  569.       Secure       : Boolean;
  570.       BadMsgs      : DosPathStr;
  571.       SaveDupesDir : DosPathStr;
  572.       MaxDupes     : SmallWord;
  573.       EchoTossLog  : DosPathStr;
  574.       StripCrash   : Boolean;
  575.       SetAKASent   : Boolean;
  576.       PvtEchoMail  : Boolean;
  577.       SaveFwdMail  : Boolean;
  578.       RouteFile    : DosPathStr;
  579.       ForwardMail  : Boolean;
  580.       KillFwdFiles : Boolean;
  581.       Filler2      : DosPathStr;
  582.       OldExt       : Boolean;
  583.       DefaultPacker: Byte;
  584.       NetMailBoard : Byte;
  585.       ForceWIPMode : Boolean;
  586.       Filler       : ARRAY[1..127] OF Char;
  587.     END;
  588.     FwdFile        : RECORD
  589.       PreCmd       : DosPathStr;        { Cmd. to run before forwarding }
  590.       SecureDir    : DosPathStr;        { Path to security directory    }
  591.       MsgAttribute : SmallWord;
  592.       KillSent     : Boolean;        { Mark msgs. as kill/sent       }
  593.       MsgPrivate   : Boolean;        { Mark msgs. as private         }
  594.       Subject      : S72;            { Subject of forward msgs.      }
  595.       Filler       : ARRAY[1..64] OF Byte;
  596.     END;
  597.     Tick : RECORD
  598.       DupeDir        : DosPathStr;          { Dupe check directory               }
  599.       HoldDir        : DosPathStr;          { Where to place outgoing .TIC files }
  600.       BeforeMoving   : DosPathStr;          { Command to execute before          }
  601.                                          { processing any ticks               }
  602.       RequestMissing : Boolean;          { Should Portal try to make a file
  603.                                          { request for any files, not received}
  604.       Filler         : ARRAY[1..64] of Byte;
  605.     END;
  606.     BiMail         : RECORD
  607.       BiOverride     : ARRAY[1..5] Of S10;   { Protocol flags to override    }
  608.                                              { full duplex max baud          }
  609.       NoSendOverride : Boolean;              { Override no send events when  }
  610.                                              { using a full duplex protocol  }
  611.       MaxBaud        : SmallWord;                 { Max. baud rate for full       }
  612.                                              { duplex.                       }
  613.       BiModemPath    : DosPathStr;              { Path & file name of BiModem   }
  614.                                              { program                       }
  615.       Filler         : ARRAY[1..16] OF Byte;
  616.     END;
  617.     NLCompiler     : RECORD
  618.       CostFileName   : DosPathStr;            { Name of cost file               }
  619.       IntPrefix      : S10;                { Int. dial prefix                }
  620.       OurPrefix      : S10;                { Prefix (direction number) of    }
  621.                                            { your country                    }
  622.       UseFidoUserLst : Boolean;            { Create FIDOUSER.LST file        }
  623.       MTypeStr       : ARRAY[0..7] OF S5;  { Node list flag for modem type   }
  624.       Filler         : ARRAY[1..64] OF Byte;
  625.     END;
  626.     DumbTerm : RECORD
  627.       CRSendsLF,                               { Make a CR after receiving a }
  628.                                                { line feed character         }
  629.       DestructiveBS : Boolean;                 { BS deletes characters       }
  630.       ModemInit     : S40;                     { Cmd. to initialize modem    }
  631.       Filler        : ARRAY[1..128] OF Byte;
  632.     END;
  633.     ExtProt : ARRAY[1..5] OF Record
  634.       Key       : Char;                      { Key to use on menu            }
  635.       Name      : S8;                        { Name of protocol              }
  636.       AskDLName : Boolean;                   { Does it need a name to be     }
  637.                                              { supplied by the user          }
  638.       AutoStart : S10;                       { STRING to detect auto-start   }
  639.       SendCmd   : DosPathStr;                   { upload command                }
  640.       RecvCmd   : DosPathStr;                   { download command              }
  641.     END;
  642.     AreaMan : RECORD
  643.       DLCntStart,                            { Character to use for start of }
  644.                                              { a download counter, in a      }
  645.                                              { FILES.BBS                     }
  646.       DLCntStop    : Char;                   { Character to use for stop of  }
  647.                                              { a download counter, in a      }
  648.                                              { FILES.BBS                     }
  649.       AdoptDefault,                          { Adopt orphans when entering a }
  650.                                              { file area                     }
  651.       InsDLCnt,                              { Insert download counters, when}
  652.                                              { entering a file area          }
  653.       AddInbound   : Boolean;                { add inbound to file area list }
  654.       FirstArea,                             { First area # (for OPUS)       }
  655.       LastArea     : Byte;                   { Last area # (for OPUS)        }
  656.       DlCDigits    : Byte;                   { Number of digits in DL Cnt    }
  657.       DlCZeroFill  : Boolean;                { Fill with zero [000] or [   ] }
  658.       ViewCMD      : S50;                    { GIF-Viewer command            }
  659.       Filler       : ARRAY[1..11] OF Byte;
  660.     END;
  661.     Packer : ARRAY[1..7] OF RECORD
  662.       AddCmd,                          { Cmd. to add files to an archive     }
  663.       UnPackCmd,                       { Cmd. to extract files from archive  }
  664.       EraseCmd,                        { Cmd. to delete files from archive   }
  665.       TestCmd    : S40;                { Cmd. to test files in an archive    }
  666.     END;
  667.   END;
  668.  
  669. {┌──────────────────────────────────────────────────────────────────────────┐}
  670. {│ Contents : Information about daily request pr system                     │}
  671. {│ FileName : PORTAL.DRI                                                    │}
  672. {│ Size     : 64 bytes                                                      │}
  673. {│ Comments : Is deleted at midnight                                        │}
  674. {└──────────────────────────────────────────────────────────────────────────┘}
  675.   PDailyReqInfo = ^TDailyReqInfo;
  676.   TDailyReqInfo = RECORD
  677.     Address  : TFidoAddress;
  678.     NumFiles : SmallWord;
  679.     NumBytes : LongInt;
  680.     UsedTime : Time;
  681.     Filler   : ARRAY[1..46] OF Byte;
  682.   END;
  683.  
  684. {┌──────────────────────────────────────────────────────────────────────────┐}
  685. {│ Contents : Undialable information.                                       │}
  686. {│ FileName : PORTAL.UDF                                                    │}
  687. {│ Size     : 13 bytes                                                      │}
  688. {│ Comments :                                                               │}
  689. {└──────────────────────────────────────────────────────────────────────────┘}
  690.   PUndialable = ^TUndialable;
  691.   TUndialable = RECORD
  692.     DelFlag     : LongInt;          { MUST BE 0 WHEN ADDING                  }
  693.     Address     : TFidoAddress;     { Address of Node                        }
  694.     NoConnect,                      { Number of BUSY's                       }
  695.     BadWaZOO    : SmallWord;             { Number of failed WaZOO's               }
  696.   END;
  697.  
  698. {┌──────────────────────────────────────────────────────────────────────────┐}
  699. {│ Contents : BadWaZOO Information.                                         │}
  700. {│ FileName : PORTAL.BWZ                                                    │}
  701. {│ Size     : 47 bytes                                                      │}
  702. {│ Comments :                                                               │}
  703. {└──────────────────────────────────────────────────────────────────────────┘}
  704.   PBadWaZOO = ^TBadWaZOO;
  705.   TBadWaZOO = RECORD
  706.     DelFlag        : LongInt;       { MUST BE 0 WHEN ADDING                  }
  707.     Address        : TFidoAddress;  { Address of Node                        }
  708.     FName          : S12;           { Original filename                      }
  709.     FSize          : LongInt;       { Original File Size                     }
  710.     FTime          : LongInt;       { Original File Time                     }
  711.     NewName        : S12;           { New filename (BADWAZOO.<Num>)          }
  712.     NodeStat       : TNodeStat;
  713.   END;
  714.  
  715. {┌──────────────────────────────────────────────────────────────────────────┐}
  716. {│ Contents : Message Areas                                                 │}
  717. {│ FileName : PORTAL.ARE                                                    │}
  718. {│ Size     : 1024                                                          │}
  719. {│ Comments : **NOT USED YET**                                              │}
  720. {└──────────────────────────────────────────────────────────────────────────┘}
  721.   TMsgArea = RECORD
  722.     Directory  : DosPathStr;           { QBBS/SBBS/RA=Board number, other=Directory path }
  723.     EchoNames  : ARRAY[1..3] Of S32;{ Echo mail tags }
  724.     Origin     : S50;               { Origin line, if any }
  725.     SendTo     : SendToType;        { Who to send to and receive from }
  726.     SendOnly   : SendToType;        { Who only to send to }
  727.     ScramblePwd: S20;               { Password }
  728.     StripSeenBy: Boolean;           { Strip seen-by down to own net + rcv. nets }
  729.     Pvt2EMail  : Boolean;
  730.     Level,                          { Security level }
  731.     Keys       : Byte;              { Security keys }
  732.     MaxScan    : SmallWord;              { Max. number of msgs. to scan per day }
  733.     ScanDate   : Date;              { Date of last scan }
  734.     Scanned    : SmallWord;              { Number of msgs. scanned on the above date }
  735.     Description: S40;               { The title or description of this area }
  736.     AreaType   : Byte;              { 0=Hudson, 1=Msg 2=Squish 3=EzyCom 4=JAM}
  737.     ImportSB   : Boolean;           { Should SEEN-BY - lines be stripped on import }
  738.     UsedAka    : Byte;              { Which AKA address to use, 0=Main address }
  739.     msgcount   : SmallWord;              { Number of msg. to keep in board}
  740.     datecount  : SmallWord;              { Number of days to keep msg. in board}
  741.     msgkeep    : byte;              { Number of start msg. to keep before sorting and deleting}
  742.     Filler     : ARRAY[1..508] of Byte;
  743.   END;
  744.  
  745. {┌──────────────────────────────────────────────────────────────────────────┐}
  746. {│ Contents : Mail schedules                                                │}
  747. {│ FileName : PORTAL.SCD                                                    │}
  748. {│ Size     : 256                                                           │}
  749. {│ Comments :                                                               │}
  750. {└──────────────────────────────────────────────────────────────────────────┘}
  751.   PSchedule = ^TSchedule;
  752.   TSchedule = RECORD
  753.     Number  : Byte;
  754.     Action  : Byte;
  755.     Adr     : SendToType;
  756.     Stat    : Char;
  757.     SubLine : Byte;
  758.     Filler  : ARRAY[1..130] OF Byte;
  759.   END;
  760.  
  761. {┌──────────────────────────────────────────────────────────────────────────┐}
  762. {│ Contents : Nodelist Segments - for Nodelist Compiler                     │}
  763. {│ FileName : PORTAL.NLS                                                    │}
  764. {│ Size     : 512 bytes                                                     │}
  765. {│ Comments : One record per used nodelist. Shared among all tasks          │}
  766. {└──────────────────────────────────────────────────────────────────────────┘}
  767.   PNodelistSeg = ^TNodelistSeg;
  768.   TNodelistSeg = RECORD
  769.     NodeListName : S8;                     { Basename of Nodelist    NODELIST }
  770.     DiffFileName : S8;                     { Basename of difffile    NODEDIFF }
  771.     CheckCRC     : Boolean;                { Check CRC on nodelist update     }
  772.     NewNLPath    : DosPathStr;                { Where to put the new packed NL   }
  773.     Include      : SendToType;             { Who to include         2:All/All }
  774.     Exclude      : SendToType;             { Who to exclude         2:230/All }
  775.     DefaultZone  : SmallInt;                { Zone to use           SA: 230694 }
  776.     NewNLDesc    : S80;                    { Description af new packed NL     }
  777.     Filler       : ARRAY[1..126] OF Byte;
  778.   END;
  779.  
  780. {┌──────────────────────────────────────────────────────────────────────────┐}
  781. {│ Contents : Misc. data and Statistics.                                    │}
  782. {│ FileName : PORTAL.DAT                                                    │}
  783. {│ Size     : 1024 bytes                                                    │}
  784. {│ Comments : One file pr. task: PORTAL<Task>.DAT                           │}
  785. {└──────────────────────────────────────────────────────────────────────────┘}
  786.   PDataFile = ^TDataFile;
  787.   TDataFile = RECORD
  788.     Event          : Byte;                       { Current event             }
  789.     Filler1        : ARRAY[1..14] OF Byte;
  790.     LastRan        : Date;                       {                           }
  791.     LastEventDate  : Date;                       {                           }
  792.     Filler2        : Byte;
  793.     LastEventStart : Time;                       {                           }
  794.     Filler3        : SmallInt;
  795.     Users          : ARRAY[1..5] OF RECORD       { Last 5 BBS Users          }
  796.       Name : S35;
  797.       T    : Time;
  798.     END;
  799.     UserTime       : LongInt;                    { Timestamp of LASTUSER file}
  800.     KbdPassword    : S20;                        { Keyboard lock password    }
  801.     Filler4        : ARRAY[1..46] OF Byte;
  802.     Calls          : ARRAY[1..2,1..5] OF RECORD  { Call's in/Out list        }
  803.       Adr : TFidoAddress;
  804.       Name: S16;
  805.       T   : Time;
  806.     END;
  807.     MacroStatus    : Boolean;                    { Keyboard macro status     }
  808.     Poll           : TFidoAddress;               { Address of last manually  }
  809.                                                  { polled node  (ALT-P)      }
  810.     LastCalled     : TFidoAddress;               { Address of last node we   }
  811.                                                  { have called               }
  812.     NextTime       : EventTimer;                 { Dial out timer            }
  813.     filler         : ARRAY[1..408] OF Char;
  814.   END;
  815.  
  816. {┌──────────────────────────────────────────────────────────────────────────┐}
  817. {│ Contents : Events                                                        │}
  818. {│ FileName : PORTAL.EVT                                                    │}
  819. {│ Size     : 128 bytes                                                     │}
  820. {│ Comments : Shared among all tasks.                                       │}
  821. {└──────────────────────────────────────────────────────────────────────────┘}
  822. CONST
  823.   { TEvent.Typ }
  824.   etForced    =     1;     { Event must run even if it is past it's time     }
  825.   etRequests  =     2;     { Allow file requests                             }
  826.   etUsers     =     4;     { Allow usesr on BBS                              }
  827.   etReceive   =     8;     { Don't send ANY mail - even if somebody poll     }
  828.   etCrash     =    16;     { Only send crash mail                            }
  829.   etNoSend    =    32;     {                                                 }
  830.   etDynamic   =    64;     {                                                 }
  831.   etClrOut    =   128;     { Clear outbound at start of event                }
  832.   etNoAnswer  =   256;     { Don't answer the phone                          }
  833.   etOnceOnly  =   512;     { Disable event when is has run                   }
  834.   etPoPList   =  1024;     { Generate filelist                               }
  835.   etTossMail  =  2048;
  836.   etScanMail  =  4096;
  837.   etPackMail  =  8192;
  838.   etNoFiles   = 16384;     { Don't send anything that is not in the outbound }
  839.   etBit15     = 32768;     { Reserved                                        }
  840.  
  841. TYPE
  842.   PEvent = ^TEvent;
  843.   TEvent = RECORD
  844.     Active       : Byte;            { BIT: 7=Active, 0..6=DayNumber          }
  845.     Start        : Time;            { Start time                             }
  846.     Month        : Byte;            { Only run on this month (1-12)          }
  847.     Day          : Byte;            { Only run on this day (1-31)            }
  848.     InitExit     : Byte;            { 0 If no exit. Exit err.level at start  }
  849.     MailExit     : Byte;            { -"- Exit err.level after rcv. mail     }
  850.     PollExit     : Byte;            { -"- Exit err.level after a poll        }
  851.     FilesExit    : Byte;            { -"- Exit err.level after rcv. file(s)  }
  852.     Typ          : LongInt;         { See above                              }
  853.     Tries        : RECORD
  854.       Bad,                          { Max number of BadWaZOO's and BUSY's    }
  855.       Busy : Byte;                  { before marking the node undialable     }
  856.     END;
  857.     CallTime     : Time;            {                                        }
  858.     CallWidth    : Time;            {                                        }
  859.     Description  : S20;             { Short description of this event        }
  860.     ConnectTo    : TFidoAddress;    { Only if not in ZMH                     }
  861.     SchedNumber  : Byte;            { Mail packer                            }
  862.     MaxCost      : SmallWord;            { Maximum cost                           }
  863.     MinMail      : LongInt;         { Minimum mail to dial out               }
  864.     SpecDial     : Byte;            { Special nodes dial number              }
  865.     TaskNumber   : Byte;            { Task number, 0=All tasks               }
  866.     Filler       : ARRAY[1..65] Of Byte;
  867.   END;
  868.  
  869. {┌──────────────────────────────────────────────────────────────────────────┐}
  870. {│ Contents : Nodes setup.                                                  │}
  871. {│ FileName : PORTAL.NOD                                                    │}
  872. {│ Size     : 256 bytes                                                     │}
  873. {│ Comments :                                                               │}
  874. {└──────────────────────────────────────────────────────────────────────────┘}
  875.   PNodeInfo = ^TNodeInfo;
  876.   TNodeInfo = RECORD
  877.     Address       : TFidoAddress;        { Node address                       }
  878.     PktPassword   : S7;                  { ** Not used yet**                  }
  879.     AreaFixPwd    : S20;                 { Password to PortalFix              }
  880.     SessionPwd    : S8;                  { Session Password                   }
  881.     PackerType    : Byte;                { 1-7 = Arcnum, 0=Arc...             }
  882.     Level         : Byte;                { Security level  of node            }
  883.     Keys          : Byte;                { Security flags of node             }
  884.     OpenFrom,                            { Used if the node is not            }
  885.     OpenTo        : Time;                { running CM                         }
  886.     UseEmsi       : Char;                { Yes, No, ' '                       }
  887.     Filler1       : ARRAY[1..20] OF Byte;
  888.     SendFwdLetter : Boolean;             { Send letter when forwarding files  }
  889.     PointNet      : SmallInt;             { Fake net if this is a node         }
  890.     CheckConnect  : Char;                { Yes, No, ' '                       }
  891.     UseFake       : Char;                { Yes, No, ' '                       }
  892.     DisallowReq   : Boolean;             {                                    }
  893.     UseFullDuplex : Char;                { Yes, No, BiModem, Janus, ' '       }
  894.     Phone         : S22;                 { Phone - Override nodelist          }
  895.     TickPassword  : S20;                 { Password for .TIC files            }
  896.     PackTick      : Boolean;             { Pack all .TIC files                }
  897.     Flavor        : Char;                { Hold, Direct, Normal, Crash,       }
  898.                                          { or Important                       }
  899.     SpecialDials  : ARRAY[0..2] OF S20;  { Used in events                     }
  900.     EMSISetTime   : Boolean;             { Set time to EMSI tranx             }
  901.     MinConnectBaud: SmallWord;                { Min baud rate to accept connect    }
  902.     NodeFiller    : ARRAY[1..59] OF Byte;
  903.   END;
  904.  
  905. {┌──────────────────────────────────────────────────────────────────────────┐}
  906. {│ Contents : Files to forward.                                             │}
  907. {│ FileName : PORTAL.FWD                                                    │}
  908. {│ Size     : 512 bytes                                                     │}
  909. {│ Comments : One record per file to forward. Shared among all tasks.       │}
  910. {└──────────────────────────────────────────────────────────────────────────┘}
  911.   PFileFwd = ^TFileFwd;
  912.   TFileFwd = RECORD
  913.     FileName     : S12;          { File mask to look for in inbound area     }
  914.     WhereToPut   : DosPathStr;      { Path to move file to                      }
  915.     AddToFiles   : Boolean;      { Add to FILES.BBS                          }
  916.     AddBeforeLine: SmallWord;         { Insert entry before line #                }
  917.     Description  : S80;          { Description to use for this file          }
  918.     SendTo       : SendToType;   { Who to send to                            }
  919.     BeforeCmd    : DosPathStr;      { Cmd. to do before moving the file         }
  920.     AfterCmd     : DosPathStr;      { Cmd. to do after moving the file          }
  921.     TouchFile    : Boolean;      { Touch the file's time stamp when moving it}
  922.     GetFrom      : TFidoAddress; { Who is allowed to send it to you          }
  923.     LastForward  : Date;         { Last date forwarded                       }
  924.     KillDupe     : Boolean;      { Kill received duplicates of this file     }
  925.     CheckDate    : Boolean;      { File must be newer than LastForaward      }
  926.     Level        : Byte;         { Security level for this entry             }
  927.     Keys         : Byte;         { Security keys for this entry              }
  928.     PortalFixName: S10;          { Name to use for it, in PortalFix          }
  929.     KeepMax      : Byte;         { How many old files to keep (0=All)        }
  930.     Filler       : ARRAY[1..44] Of Byte;
  931.   END;
  932.  
  933.  
  934. {┌──────────────────────────────────────────────────────────────────────────┐}
  935. {│ Contents : Phone translations for Nodelist Compiler.                     │}
  936. {│ FileName : PORTAL.NLT                                                    │}
  937. {│ Size     : 64 bytes                                                      │}
  938. {│ Comments :                                                               │}
  939. {└──────────────────────────────────────────────────────────────────────────┘}
  940.   TNLTranslat = RECORD
  941.     NumFrom,                     { If phone number starts with this   }
  942.     NumTo      : S31;            { Replace it with this!!             }
  943.   END;
  944.   NLTranslatTab = ARRAY[1..1000] OF TNLTranslat;    { For typecasting }
  945.  
  946.  
  947. {┌──────────────────────────────────────────────────────────────────────────┐}
  948. {│ Contents : Ok-File (File request)                                        │}
  949. {│ FileName : PORTAL.OKF                                                    │}
  950. {│ Size     : 128 bytes                                                     │}
  951. {│ Comments :                                                               │}
  952. {└──────────────────────────────────────────────────────────────────────────┘}
  953.   TFreeArea = (faNoWay,          { Not a free area                           }
  954.                faIfAccess,       { If file within limits, send it but don't  }
  955.                                  { add it to limits (same limits after file) }
  956.                faTotally);       { Totally free - only check time to next    }
  957.                                  { NoRequest event                           }
  958.  
  959.   POkFile = ^TOkFile;
  960.   TOkFile = RECORD
  961.     NodeStat  : TNodeStat;       { Nodestat:                                 }
  962.     MagicName : S20;             { Magic name, if any                        }
  963.     FilePath  : DosPathStr;         { Path and filespec.                        }
  964.     Password  : S10;             { Password for area                         }
  965.     Level,
  966.     Keys      : Byte;
  967.     FreeArea  : TFreeArea;
  968.     TaskNumber: Byte;
  969.     Filler    : ARRAY[1..11] of Byte;
  970.   END ;
  971.  
  972.  
  973. {┌──────────────────────────────────────────────────────────────────────────┐}
  974. {│ Contents : Tick areas setup.                                             │}
  975. {│ FileName : PORTAL.TIC                                                    │}
  976. {│ Size     : 512 bytes                                                     │}
  977. {│ Comments :                                                               │}
  978. {└──────────────────────────────────────────────────────────────────────────┘}
  979.   PTickArea = ^TTickArea;
  980.   TTickArea = RECORD
  981.     AreaName      : S20;         { Name of the area                          }
  982.     GroupName     : S10;         { All areas with same group name is         }
  983.                                  { announced in same letter                  }
  984.     HumanName     : S40;         { Human understandable areaname             }
  985.     AreaPath      : DosPathStr;     { Where to copy to                          }
  986.     WriteLetter   : Boolean;     { Write letter when files arrive            }
  987.     AnnouncePath  : DosPathStr;     { Where to write letter                     }
  988.     CanBeRepacked : Boolean ;    { Allow other ext. than in .TIC             }
  989.     GetFrom       : SendToType;  { These nodes can hatch into this area      }
  990.     SendTo        : SendToType;  { These nodes can only receive files in     }
  991.                                  { this area                                 }
  992.     Level,Keys    : Byte;        { Level and Keys needed to access this area }
  993.     CheckCRC      : Boolean;     { Check CRC in this area                    }
  994.     FilesBBS      : S12;         { Name of file to update                    }
  995.     AKAToUse      : Byte;        { Which AKA to use (0=Main address)         }
  996.     CheckDupe     : Boolean;     { Should this area be checked for dupes     }
  997.     Filler        : ARRAY[1..55] Of Byte;
  998.   END;
  999.  
  1000.  
  1001. {┌──────────────────────────────────────────────────────────────────────────┐}
  1002. {│ Contents : Intercommunication.                                           │}
  1003. {│ FileName : PORTAL.ICF                                                    │}
  1004. {│ Size     : 32 bytes                                                      │}
  1005. {│ Comments :                                                               │}
  1006. {└──────────────────────────────────────────────────────────────────────────┘}
  1007. CONST
  1008.   ICUnused     = $00;    { Informal }
  1009.   ICIdle       = $01;    { Informal }
  1010.   ICAreaMan    = $02;    { Informal }
  1011.   ICTextEdit   = $03;    { Informal }
  1012.   ICDumbTerm   = $04;    { Informal }
  1013.   ICDosShell   = $05;    { Informal }
  1014.   ICUserInBBS  = $06;    { Informal }
  1015.   ICMsgEdit    = $07;    { Informal }
  1016.   ICConfig     = $08;    { Informal }
  1017.   ICSemExit    = $09;
  1018.  
  1019.   ICPolling    = $80;
  1020.   ICFileFwd    = $81;
  1021.   ICConnect    = $82;
  1022.   ICNLComp     = $83;
  1023.   ICUnpackMail = $84;
  1024.   ICOutMan     = $85;
  1025.   ICNLMan      = $86;
  1026.   ICUserEd     = $87;
  1027.   ICScanNetMail= $88;
  1028.   ICTick       = $89;
  1029.  
  1030. { ToDoFlags: }
  1031.   ICTDUnpackMail  = $0001;
  1032.   ICTDReReadNLIdx = $0002;
  1033.  
  1034.  
  1035. TYPE
  1036.   PInterCom = ^TInterCom;
  1037.   TInterCom = RECORD
  1038.     Status     : Byte;
  1039.     MyAddress,
  1040.     PollAddress: TFidoAddress;
  1041.     ToDoFlags  : SmallWord;
  1042.     Filler     : ARRAY[1..13] of Byte;
  1043.   END;
  1044.  
  1045.  
  1046. { ┌─────────────────────────────────────────────────────────────────────────┐ }
  1047. { │ Contents : Information about received files.                            │ }
  1048. { │ FileName : PORTAL.TIT                                                   │ }
  1049. { │ Size     : 64 bytes                                                     │ }
  1050. { │ Comments :                                                              │ }
  1051. { └─────────────────────────────────────────────────────────────────────────┘ }
  1052.   TInboundFile = RECORD
  1053.     DelFlag    : LongInt;
  1054.     FileName   : S8;                   { Filename                             }
  1055.     From       : TFidoAddress;         { Address of node we got the file from }
  1056.     RecvDate   : Date;                 { Date received                        }
  1057.     RecvTime   : Time;                 { Time received                        }
  1058.     TaskNum    : Byte;                 { Received on tasknumber               }
  1059.     Filler     : ARRAY[1..34] OF Byte;
  1060.   END;
  1061.  
  1062.  
  1063. { ┌─────────────────────────────────────────────────────────────────────────┐ }
  1064. { │ Contents : Text Editor pick list.                                       │ }
  1065. { │ FileName : PORTAL.TEP                                                   │ }
  1066. { │ Size     : ?? bytes                                                     │ }
  1067. { │ Comments :                                                              │ }
  1068. { └─────────────────────────────────────────────────────────────────────────┘ }
  1069.   TPickList = RECORD
  1070.     FileName   : DosPathStr;
  1071.     LineAtTop  : SmallInt;
  1072.     CurLine    : SmallInt;
  1073.     CurCol     : Byte;
  1074.     BlkBegin,
  1075.     BlkEnd     : MarkerRec;
  1076.     SearchStr,
  1077.     ReplaceStr : STRING[MaxSearchLen];
  1078.     OptionStr  : STRING[MaxSearchOptions];
  1079.     LastSearch : Byte;
  1080.     Filler     : ARRAY[1..94] of Byte;
  1081.   END;
  1082.   PickListArrayType = ARRAY[0..15] Of TPickList;
  1083.  
  1084.  
  1085. {┌──────────────────────────────────────────────────────────────────────────┐}
  1086. {│ Contents : Dialing directory for Terminal mode                           │}
  1087. {│ FileName : PORTAL.TDD                                                    │}
  1088. {│ Size     : 128 bytes                                                     │}
  1089. {│ Comments : One record per entry                                          │}
  1090. {└──────────────────────────────────────────────────────────────────────────┘}
  1091.   TDialDir = RECORD
  1092.     Name           : S30;                   { Name of the board              }
  1093.     Phone          : S20;                   { Phone number                   }
  1094.     TermMode       : Byte;                  { Emulation. 0=Auto, 1=ANSI-BBS, }
  1095.                                             {            2=AVATAR            }
  1096.     Settings       : SmallWord;                  { Not used yet                   }
  1097.     Filler         : ARRAY[1..73] OF Char;
  1098.   END;
  1099.  
  1100.  
  1101. {┌──────────────────────────────────────────────────────────────────────────┐}
  1102. {│ Contents : Portal Statistics                                             │}
  1103. {│ FileName : PORTAL.STA                                                    │}
  1104. {│ Size     : 8192 bytes                                                    │}
  1105. {│ Comments :                                                               │}
  1106. {└──────────────────────────────────────────────────────────────────────────┘}
  1107. CONST
  1108.   CSMail        = 0;
  1109.   CSUser        = 1;
  1110.   CSIn          = 0;
  1111.   CSOut         = 1;
  1112.  
  1113.   USUser        = 0;
  1114.   USMailIn      = 1;
  1115.   USMailOut     = 2;
  1116.   USMailProcess = 3;
  1117.  
  1118. TYPE
  1119.   PPortalStat = ^TPortalStat;
  1120.   TPortalStat = RECORD
  1121.     Start     : DateTimeRec;                     { Start date/time of stat   }
  1122.     Usage     : ARRAY[0..6,DayType,0..23] OF LongInt; { Connect time/day/hour}
  1123.     Connect   : RECORD
  1124.       Bauds    : ARRAY[0..MaxBaudStat] OF SmallWord;     { Baudrates - NOT sorted }
  1125.       Protocol : ARRAY[0..MaxBaudStat] OF S5;
  1126.       Stat     : ARRAY[CSMail..CSUser,CSIn..CSOut,0..MaxBaudStat] OF LongInt;
  1127.     END;
  1128.     DayStat   : ARRAY[0..1] OF RECORD            { Today/Yesterday           }
  1129.       CallsOut      : SmallWord;
  1130.       CallsGood     : SmallWord;
  1131.       Cost          : SmallWord;
  1132.       BbsSessions   : SmallWord;
  1133.       MailSessions  : SmallWord;
  1134.       FilesIn       : SmallWord;
  1135.       FilesOut      : SmallWord;
  1136.     END;
  1137.     Total     : RECORD
  1138.       CallsOut      : LongInt;
  1139.       CallsGood     : LongInt;
  1140.       Cost          : LongInt;
  1141.       BbsSessions   : LongInt;
  1142.       MailSessions  : LongInt;
  1143.       FilesIn       : LongInt;
  1144.       FilesOut      : LongInt;
  1145.     END;
  1146.     Filler  : ARRAY[0..1959] OF Byte;
  1147.   END;
  1148.  
  1149.  
  1150. {┌──────────────────────────────────────────────────────────────────────────┐}
  1151. {│ Contents : Portal incomming/outgoing mailer calls                        │}
  1152. {│ FileName : PORTAL.SCI  PORTAL.SCO                                        │}
  1153. {│ Size     : 256 bytes                                                     │}
  1154. {│ Comments : .SCI=Calls in, .SCO=Calls out                                 │}
  1155. {└──────────────────────────────────────────────────────────────────────────┘}
  1156.   PCallStat = ^TCallStat;
  1157.   TCallStat = RECORD
  1158.     Start        : DateTimeRec;
  1159.     Finish       : DateTimeRec;
  1160.     Address      : TFidoAddress;
  1161.     MailerType   : Byte;
  1162.     SystemName   : S60;
  1163.     SysOpName    : S20;
  1164.     FilesIn      : SmallWord;
  1165.     FilesOut     : SmallWord;
  1166.     Cost         : LongInt;         { Only on outgoing calls }
  1167.     ConnectSpeed : LongInt;
  1168.     Filler       : Array[1..137] of Byte;
  1169.   END;
  1170.  
  1171.  
  1172. {┌──────────────────────────────────────────────────────────────────────────┐}
  1173. {│ Contents : Portal color schemes                                          │}
  1174. {│ FileName : *.CLR                                                         │}
  1175. {│ Size     : 512 bytes                                                     │}
  1176. {│ Comments :                                                               │}
  1177. {└──────────────────────────────────────────────────────────────────────────┘}
  1178.   PColorScheme = ^TColorScheme;
  1179.   TColorScheme = RECORD
  1180.     Color   : ARRAY[1..4] OF ColorSet;
  1181.     Desc    : S40;
  1182.     MadeBy  : S20;
  1183.     Address : TFidoAddress;
  1184.     Filler  : ARRAY[1..194] OF Byte;
  1185.   END;
  1186.  
  1187.  
  1188. {┌──────────────────────────────────────────────────────────────────────────┐}
  1189. {│ Contents : Multiple FileList Segments                                    │}
  1190. {│ FileName : PORTAL.MFS                                                    │}
  1191. {│ Size     : 512 bytes                                                     │}
  1192. {│ Comments :                                                               │}
  1193. {└──────────────────────────────────────────────────────────────────────────┘}
  1194.   PFileListSegment = ^TFileListSegment;
  1195.   TFileListSegment = RECORD
  1196.     Name          : S20;         { Name of the Segment                       }
  1197.     Filename      : DosPathStr;     { Segment filename                          }
  1198.     HeaderFile    : DosPathStr;     { Segment header filename                   }
  1199.     IncludeAreas  : ARRAY[1..4] of S50; { Arrays to include in this segment  }
  1200.     DoAfter       : DosPathStr;     { Do after each segment                     }
  1201.     Filler        : ARRAY[1..47] Of Byte;
  1202.   END;
  1203.  
  1204.  
  1205.  
  1206. { ┌─────────────────────────────────────────────────────────────────────────┐ }
  1207. { │ BiModem Stuff - see BiModem manual for more info!                       │ }
  1208. { └─────────────────────────────────────────────────────────────────────────┘ }
  1209.   TBiModemCfg = RECORD
  1210.     MaxTime100         : Byte;
  1211.     MaxTimeSec         : Byte;
  1212.     MaxTimeMin         : Byte;
  1213.     MaxTimeHour        : Byte;
  1214.     MaxSize            : LongInt;
  1215.     BaudRate           : LongInt;
  1216.     ComPort            : Byte;
  1217.  
  1218.     IntReqPort1        : Byte;
  1219.     PortAddr1          : SmallInt;
  1220.     IntReqPort2        : Byte;
  1221.     PortAddr2          : SmallInt;
  1222.     IntReqPort3        : Byte;
  1223.     PortAddr3          : SmallInt;
  1224.     IntReqPort4        : Byte;
  1225.     PortAddr4          : SmallInt;
  1226.     IntReqPort5        : Byte;
  1227.     PortAddr5          : SmallInt;
  1228.     IntReqPort6        : Byte;
  1229.     PortAddr6          : SmallInt;
  1230.     IntReqPort7        : Byte;
  1231.     PortAddr7          : SmallInt;
  1232.     IntReqPort8        : Byte;
  1233.     PortAddr8          : SmallInt;
  1234.  
  1235.     BitMap1            : Byte;
  1236.     BitMap2            : Byte;
  1237.     BitMap3            : Byte;
  1238.     BitMap4            : Byte;
  1239.     DefaultSend        : STRING[79];
  1240.     DefaultReceive     : STRING[79];
  1241.     DefaultLogPath     : STRING[79];
  1242.     DefaultPathFile    : STRING[79];
  1243.     RemoveSnow         : Char;
  1244.     ModemType          : Char;
  1245.     BiosIndicator      : Char;
  1246.     UseCTS             : Char;
  1247.     UseCarrier         : Char;
  1248.     UseDSR             : Char;
  1249.     ReplaceTimer       : Char;
  1250.     ReplaceKbd         : Char;
  1251.     PromptColor        : Byte;
  1252.     FieldColor         : Byte;
  1253.     CharRcvColor       : Byte;
  1254.     ChatSendColor      : Byte;
  1255.     MenuCurColor       : Byte;
  1256.     MenuNotCurColor    : Byte;
  1257.     WaitForConnect     : SmallInt;
  1258.     StartPageMin       : Byte;
  1259.     StartPageHour      : Byte;
  1260.     EndPageMin         : Byte;
  1261.     EndPageHour        : Byte;
  1262.     PhoneEdit          : STRING[12];
  1263.     RejectListPath     : STRING[79];
  1264.     AbortPath          : STRING[79];
  1265.     CurDirAccess       : Char;
  1266.     RemoteFReq         : Char;
  1267.     LocalFReq          : Char;
  1268.     BiHotActKey        : SmallInt;
  1269.     BiHotActKeyName    : STRING[5];
  1270.     BiHotUnLoadKey     : SmallInt;
  1271.     BiHotUnloadKeyName : STRING[5];
  1272.     PwdFilePath        : STRING[79];
  1273.   { --- NEW IN BIMODEM v1.22 --- }
  1274.     MaxErrPrFile       : SmallInt;
  1275.     MenuNotCurMarkColor: Byte;
  1276.     MenuCurMarkColor   : Byte;
  1277.     ErrorColor         : Byte;
  1278.     BiListFilePath     : STRING[79];
  1279.     SkipIfSameDate     : Char;
  1280.  
  1281.   END;
  1282.  
  1283.   TBiModemInterComm = RECORD
  1284.     DayTransComp  : Byte;
  1285.     MonthTransComp: Byte;
  1286.     YearTransComp : SmallInt;
  1287.     TransComp100  : Byte;
  1288.     SecTransComp  : Byte;
  1289.     MinTransComp  : Byte;
  1290.     HourTransComp : Byte;
  1291.     Direction     : Char;
  1292.     FilePath      : STRING[78];
  1293.     Status        : Char;
  1294.     Description   : STRING[79];
  1295.     Cps           : SmallWord;
  1296.     RegID         : STRING[59];
  1297.     AreaCodePhone : SmallInt;
  1298.     RestPhone1    : Byte;
  1299.     RestPhone2    : Byte;
  1300.     RestPhone3    : Byte;
  1301.   END;
  1302.  
  1303.   TBiModemTransfer = RECORD
  1304.     Direction,
  1305.     Refresh,
  1306.     ReplaceExist,
  1307.     VerifyWhenDone,
  1308.     DeleteSource,
  1309.     Filler,
  1310.     AllowDirectory,
  1311.     IncludeSubs    : Char;
  1312.     Source,
  1313.     Destination,
  1314.     Description    : ARRAY[1..80] OF Char;
  1315.   END;
  1316.  
  1317.   RunParametersType=RECORD
  1318.     Toss,
  1319.     Scan,
  1320.     Pack   : Boolean;
  1321.     Sched  : BYTE;
  1322.   END;
  1323.  
  1324.   PPopEdHeader = ^TPopEdHeader;
  1325.   TPopEdHeader = RECORD
  1326.     FromName  : S35;
  1327.     FromAddr  : s20;
  1328.     ToName    : S35;
  1329.     ToAddr    : s20;
  1330.     Subj      : S72;
  1331.     Flags     : LongInt;
  1332.   END;
  1333.  
  1334. { ┌─────────────────────────────────────────────────────────────────────────┐ }
  1335. { │ Hudson message base structures                                          │ }
  1336. { └─────────────────────────────────────────────────────────────────────────┘ }
  1337.   HudsonInfoRecord = Record
  1338.     LowMsg:      SmallInt;
  1339.     HighMsg:     SmallInt;
  1340.     TotalActive: SmallInt;
  1341.     ActiveMsgs:  Array[1..200] of SmallInt;
  1342.   End;
  1343.  
  1344.   HudsonIdxRecord = Record
  1345.     MsgNum:       SmallInt;
  1346.     Board:        Byte;
  1347.   End;
  1348.  
  1349. (* Msg Attributes: (MsgAttr: Byte)
  1350.       Bit 0: Deleted
  1351.       Bit 1: Unmoved Outgoing Net Message
  1352.       Bit 2: Is a Net Mail Message
  1353.       Bit 3: Private
  1354.       Bit 4: Received
  1355.       Bit 5: Unmoved Outgoing Echo Message
  1356.       Bit 6: Local Bit
  1357.  
  1358.    Net Attributes: (NetAttr: Byte)
  1359.       Bit 0: Kill Message after it's been sent
  1360.       Bit 1: Sent OK
  1361.       Bit 2: File(s) Attached
  1362.       Bit 3: Crash Priority
  1363.       Bit 4: Request Receipt
  1364.       Bit 5: Audit Request
  1365.       Bit 6: Is a Return Receipt *)
  1366.  
  1367.   HudsonHdrRecord = Record
  1368.     MsgNum,
  1369.     ReplyTo,
  1370.     SeeAlsoNum,
  1371.     TRead:              SmallInt;
  1372.     StartRec:           SmallWord;
  1373.     NumRecs,
  1374.     DestNet,
  1375.     DestNode,
  1376.     OrigNet,
  1377.     OrigNode:           SmallInt;
  1378.     DestZone,
  1379.     OrigZone:           Byte;
  1380.     Cost:               SmallInt;
  1381.     MsgAttr,
  1382.     NetAttr,
  1383.     Board:              Byte;
  1384.     PostTime:           S5;
  1385.     PostDate:           S8;
  1386.     WhoTo,
  1387.     WhoFrom:            S35;
  1388.     Subj:               S72;
  1389.   End;
  1390.  
  1391. CONST
  1392.   { MsgAttr : BYTE }
  1393.   qbDeleted    = 1;
  1394.   qbPrivate    = 8;
  1395.   qbReceived   = 16;
  1396.   qbLocal      = 64;
  1397.  
  1398.   { NetAttr : BYTE }
  1399.   qbKill       = 1;
  1400.   qbSent       = 2;
  1401.   qbFileAttach = 4;
  1402.   qbCrash      = 8;
  1403.   qbReqRcpt    = 16;
  1404.   qbAuditReq   = 32;
  1405.   qbReturnRcpt = 64;
  1406.  
  1407. IMPLEMENTATION
  1408.  
  1409. END.
  1410.  
  1411.